import request from '@/utils/request'


export function templateList() {
  return request({
    url: '/hawk-eye/template/template-list',
    method: 'get'
  })
}

export function defaultTemplate() {
  return request({
    url: '/hawk-eye/template/default-template',
    method: 'get'
  })
}

export function templatePageList(query) {
  return request({
    url: '/hawk-eye/template/page',
    method: 'get',
    params: query
  })
}

export function templateDetail(id) {
  return request({
    url: '/hawk-eye/template/detail/' + id,
    method: 'get'
  })
}

export function addTemplate(data) {
  return request({
    url: '/hawk-eye/template/save',
    method: 'post',
    data: data
  })
}

export function updateTemplate(data) {
  return request({
    url: '/hawk-eye/template/update',
    method: 'put',
    data: data
  })
}

export function removeTemplate(id) {
  return request({
    url: '/hawk-eye/template/remove/' + id,
    method: 'delete'
  })
}
